from django.db import models

# Create your models here.

class UserInfo(models.Model):
    name = models.CharField(max_length=32)
    password = models.CharField(max_length=64)
    age = models.IntegerField()
    # gender = models.CharField(max_length=32,default="男")#如果已经有表再添加字段，默认值必须有
    # email = models.EmailField(null= True,blank=True)#接上面，或者允许为空
"""
ORM将会创建一个表
create table app01_Sserinfo(
    id bigint auto_increment primary key,
    name varchar(32),
    password varchar(64),
    age omt

)

"""
class Department(models.Model):
    title = models.CharField(max_length=32) #"如果不想要某个表或者某个元素，删除即可“